﻿using log4net;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace TestWebRole
{
    public partial class _Default : Page
    {
        private static log4net.ILog _logger;

        static _Default()
        {
            log4net.Config.XmlConfigurator.Configure();

            _logger = LogManager.GetLogger("default");
        }
  
        protected void Page_Load(object sender, EventArgs e)
        {
            BtnSend.Click += BtnSend_Click;
        }

        void BtnSend_Click(object sender, EventArgs e)
        {
            if (!string.IsNullOrEmpty(MessageBox.Text))
            {
                _logger.Info(MessageBox.Text); 
            }   
        }
    }
}